<?php

namespace App\Http\Controllers\Api\V1;

use Carbon\Carbon;
use App\Models\Type;
use Illuminate\Support\Facades\DB;
use App\Http\Controllers\Api\V1\Resources\TypeResource;

class TypesController extends Controller
{
	public function index()
	{
		
		$types = Type::query()
			->where('is_shown',true)
			->orderBy("order")
			->get();
		
		return TypeResource::collection($types);
	}

	public function all()
	{
		
		$screens = Type::query()
			->orderBy("order")
			->get();
		
		return TypeResource::collection($screens);
	}
} 
